import http from '../../util/request.js'

export default {
    // 获取交易记录分页数据
    page: (params) => {
        return http({
            url: '/manager/transaction/page',
            method: 'GET',
            params: params
        });
    },

    // 删除交易记录
    delete: (id) => {
        return http({
            url: `/manager/transaction/${id}`,
            method: 'DELETE'
        });
    },

    // 获取交易趋势数据
    getTrendData: (params) => {
        return http({
            url: '/manager/transaction/trend',
            method: 'GET',
            params: params
        });
    },

    // 获取地陪收入排行数据
    getGuideRankData: () => {
        return http({
            url: '/manager/transaction/guide-rank',
            method: 'GET'
        });
    },

    // 获取游客消费分布数据
    getVisitorDistributionData: () => {
        return http({
            url: '/manager/transaction/visitor-distribution',
            method: 'GET'
        });
    }
}
